home *** CD-ROM | disk | FTP | other *** search
- Path: alpha1.csd.uwm.edu!gidwani
- From: gidwani@alpha1.csd.uwm.edu (Vinay K Gidwani)
- Newsgroups: comp.lang.c
- Subject: formatting integers
- Date: 29 Mar 1996 03:53:53 GMT
- Organization: University of Wisconsin - Milwaukee, Computing Services Division
- Sender: gidwani@alpha1.csd.uwm.edu
- Distribution: usa
- Message-ID: <4jfmsh$lal@uwm.edu>
- NNTP-Posting-Host: 129.89.169.1
-
- I am trying to format an integer that is left justified, length of 4 and
- 0 filled.
-
- I tried the following %-0*%d and typed in the length of 4, but it gave me
- the following output
-
- 4.
- When I try %0*d, then I get the following output.
- 0004.
- The length and the 0 filled in works but I cannot get it to left
- justify.
-
- Any pointers in this would be helpful.
-
- My email is gidwani@alpha1.csd.uwm.edu
-
- Thanks
-
- Vinay.
-
-
- --
- email : gidwani@alpha1.csd.uwm.edu
-